//package top.zxybird.yun.grift
//
//import top.zxybird.yun.rpc.thrift.ast.Nodes
//import top.zxybird.yun.rpc.thrift.ast.ThriftParser
//
///**
// * Created by zxybird on 2018/3/15.
// */
//
//// 存储document
//document = ThriftParser.parseThriftFileAst("/api.thrift").get()
//
//conn = {}
//
//static findNamespace(document) {
//  for (header in document.headers) {
//    if (header.value instanceof Nodes.GeneralNamespaceNode) {
//      return ((Nodes.GeneralNamespaceNode) header.value).identifier.name
//    }
//  }
//  return null
//}
//
//static findStruct(document) {
//  def ret = []
//  for (node in document.definitions) {
//    if (node.value instanceof Nodes.StructNode) {
//      ret.add(node)
//    }
//  }
//  return ret
//}
//
//
//conn.namespace = findNamespace(document)
//conn.structList = findStruct(document)
//
////println conn.structList
//println document.printTree()
////println conn.namespace
////
////conn.name = 'zxy'
////
////print conn.name
////
//
////System.out.println(document.printTree());
//
////println document.headers.get(0).type
////println document.headers.get(0).args
//
////def class Conn {
////    protected dynamicProps = [:]
////
////    void setProperty(String pName, val) {
////        dynamicProps[pName] = val
////    }
////
////    def getProperty(String pName) {
////        dynamicProps[pName]
////    }
////}
////
////def conn = new Conn()
////
////conn.name = 'zxy'
////
////print conn.name
////
